home *** CD-ROM | disk | FTP | other *** search
- #ifndef FORMCONV_H
- #define FORMCONV_H
- #include "common.h"
- #include "grfile.h"
-
- /*
- * The headers of various routines that convert image forms
- * from one to another
- * All of them work with a single line of image.
- *
- * And one important note!!!
- * YOU MUST reserve one extra byte in destination line,
- * (please, forgive me) some procedures tends to write to this byte
- *
- * Written by E. Podvoysky & Kiselev J. CZ 1994.
- */
-
- /* see image form descriptions in grfile.h */
-
- void invert_order(BYTE *source,BYTE *dest,int width);
-
- void mono2row(BYTE *source,BYTE *dest,BYTE whitecolor,int width);
- void monoGIF2mono(BYTE *source,BYTE *dest,int width);
- void mono2GIFmono(BYTE *source,BYTE *dest,int width);
- void mono2mono(BYTE *source,BYTE *dest,int width);
- void mono2RGB24(BYTE *source,BYTE *dest,int width);
- void gray2byte(BYTE *source,BYTE *dest,int width);
- void col2562byte(BYTE *source,BYTE *dest,int width);
-
- void col16A2col16B(BYTE *source,BYTE *dest,int width);
- // beware - writes one excessive byte to dest if width is odd
- void col16B2col16A(BYTE *source,BYTE *dest,int width);
-
- void col16plane2col16B(BYTE *source,BYTE *dest,int width);
- void col16B2col16plane(BYTE *source,BYTE *dest,int width);
- void palette2gray(BGRpalette source,BGRpalette dest);
-
- void mono2RGBlines(BYTE *source, BYTE *dest,int width);
- void byte2RGBlines(BYTE *source, BYTE *dest,int width, BGRpalette pal);
- void paletted2gray(BYTE *source, BYTE *dest,int width, BGRpalette graypal);
-
-
- void BGR2RGBlines(BYTE *source, BYTE *dest, int width);
- void RGB15_2RGBlines(BYTE *source, BYTE *dest, int width);
- void RGB16_2RGBlines(BYTE *source, BYTE *dest, int width);
- void BGRA32_2RGBlines(BYTE *source, BYTE *dest, int width);
- void RGBplanes2RGBlines(BYTE *source, BYTE *dest, int width);
-
- void RGBlines2BGR(BYTE *source, BYTE *dest, int width);
- void RGBlines2RGB15(BYTE *source, BYTE *dest, int width);
- void RGBlines2BGRA32(BYTE *source, BYTE *dest, int width);
- void RGBlines2gray(BYTE *source, BYTE *dest, int width);
-
- typedef void (*getRGBlines)(BYTE *source, BYTE *dest, int width);
- getRGBlines getRGBproc(image_type source_type, image_extention_type source_ext);
-
-
- #endif
-